<div class="row">
  <div class="col-12">
    <nb-card>
      <nb-card-header>
        <div class="d-flex justify-content-between align-items-center">
          <h5>集群列表</h5>
          <button nbButton status="primary" (click)="onCreate()">
            <nb-icon icon="plus-outline"></nb-icon>
            添加集群
          </button>
        </div>
      </nb-card-header>
      <nb-card-body>
        <div *ngIf="loading" class="text-center">
          <nb-spinner status="primary"></nb-spinner>
        </div>

        <ng2-smart-table
          *ngIf="!loading"
          [settings]="settings"
          [source]="source"
          (edit)="onEdit($event)"
          (delete)="onDelete($event)"
          (userRowSelect)="onRowSelect($event)"
        >
        </ng2-smart-table>
      </nb-card-body>
    </nb-card>
  </div>
</div>

